-
Notifications
You must be signed in to change notification settings - Fork 233
chore(components): update Code to latest; adjust component usage to new interface COMPASS-9925 #7424
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Conversation
@@ -9643,6 +10107,482 @@ | |||
"@leafygreen-ui/leafygreen-provider": "^5.0.4" | |||
} | |||
}, | |||
"node_modules/@lg-tools/build": { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Most of 4k+ LoC changes in this file are due to this, seems like one of the packages that code pulls in has their whole build toolchain in dependencies. I think we should wait for LG team to fix this before merging (I asked about it in their channer)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good. I have no idea why I ran the script and got a different result 😬
// exit details | ||
// leafygreen autofocus triggers a tooltip on the error code element, | ||
// "Tab" to remove the focus | ||
await browser.keys('Tab'); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
All three e2e tests failing after the update were caused by the leafygreen autofocus first thing in the modal behavior. The way of dealing with it is the same everywhere and it's more than two places, but I still didn't feel like it warrants a shared helper of some kind. Tell me if you have a different opinion on this
This patch updates leafygreen Code component to latest to fix the copy button behavior: seems like in our current version it doesn't work inside the leafygreen chatbot element. Most notable changes are inside the "Export to language" feature: the Code component now doesn't include the code selector panel by default, so code around there had to be changed to account for that. Otherwise it's just slight visual changes in a couple of places:
Checks are passing, but pretty sure this will break tests that rely on testids, opening PR already to see how big the damage is.
Also package-lock update looks ridiculous because leafygreen deps are pulling in their whole toolchain inside our dependencies. I asked them about this and waiting for them to clean this up.